﻿<Window x:Class="NDatabase.LinqPad.Driver.ConnectionDialog"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="NDatabase Connection" SizeToContent="Height"
        WindowStartupLocation="CenterScreen" Background="{x:Static SystemColors.ControlBrush}" Width="336" >
    <StackPanel Margin="7">

        <DockPanel>
            <Label DockPanel.Dock="Right" Padding="1">
                <Hyperlink Click="BrowseCustomAssemblyClick">Browse...</Hyperlink>
            </Label>
            <Label Padding="0,0,0,1" DockPanel.Dock="Left">Path to custom assembly:</Label>
        </DockPanel>
        <TextBox Text="{Binding CustomTypeInfo.CustomAssemblyPath}" Margin="0,0,0,6" />

        <DockPanel>
            <Label DockPanel.Dock="Right" Padding="1">
                <Hyperlink Click="ChooseClick">Choose...</Hyperlink>
            </Label>
            <Label Padding="0,0,0,1" DockPanel.Dock="Left">Full name of custom type:</Label>
        </DockPanel>
        <TextBox Text="{Binding CustomTypeInfo.CustomTypeName}" Margin="0,0,0,12" />

        <DockPanel>
            <Label DockPanel.Dock="Right" Padding="1">
                <Hyperlink Click="BrowseAppConfig">Browse...</Hyperlink>
            </Label>
            <Label Padding="0,0,0,1">Application config file (if required):</Label>
        </DockPanel>

        <TextBox Name="txtAppConfigPath" Margin="0,0,0,12" Text="{Binding AppConfigPath}"/>

        <CheckBox IsChecked="{Binding Persist}">
            Remember this connection
        </CheckBox>

        <DockPanel LastChildFill="False" Margin="0,8,0,0">
            <Button Name="btnCancel" DockPanel.Dock="Right" Content="Cancel" Margin="5,0,0,0" Padding="8,3"
                    MinWidth="60" IsCancel="True" TabIndex="2" />
            <Button Name="btnOK" DockPanel.Dock="Right" Content="OK" Margin="5,0,0,0" Padding="8,3" MinWidth="60"
                    IsDefault="True" TabIndex="1" Click="OkClick" />
        </DockPanel>
    </StackPanel>
</Window>